473,461 Members | 1,679 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

encrypt the querystring values for a HyperLinkColumn

TJS
how can I encrypt the querystring values for a HyperLinkColumn ?

in example below I would like to encrypt value for field1
================================================== ====
<asp:HyperLinkColumn Text="View" DataNavigateUrlField="field1"
DataNavigateUrlFormatString="page.aspx?idx={0}"></asp:HyperLinkColumn>
Nov 18 '05 #1
3 3353
-----Original Message-----
how can I encrypt the querystring values for a HyperLinkColumn ?
in example below I would like to encrypt value for field1
================================================= =====
<asp:HyperLinkColumn Text="View" DataNavigateUrlField="field1"DataNavigateUrlFormatString="page.aspx?idx= {0}"></asp:HyperLinkColumn>

.I had the same question, and the following seems to work. You have to use an <asp:TemplateColumn> instead of
a hyperlinkcolumn, however.

<asp:TemplateColumn HeaderText="Course (Click to Edit)">
<HeaderStyle HorizontalAlign="Left"></HeaderStyle>
<ItemTemplate>
<asp:HyperLink Runat="server" text='<%#
DataBinder.Eval(Container, "DataItem.Course_Code") %>'
navigateurl='<%
# "CourseDetails.aspx?index=0&ID=" & _
Server.URLEncode(DataBinder.Eval
(Container, "DataItem.Course_Code")) %>' />
</ItemTemplate>
</asp:TemplateColumn>
HTH.

Nov 18 '05 #2
TJS
thank you !

"fe********@seattletimes.com" <an*******@discussions.microsoft.com> wrote in
message news:17****************************@phx.gbl...
-----Original Message-----
how can I encrypt the querystring values for a

HyperLinkColumn ?

in example below I would like to encrypt value for field1
================================================= =====
<asp:HyperLinkColumn Text="View"

DataNavigateUrlField="field1"
DataNavigateUrlFormatString="page.aspx?idx=

{0}"></asp:HyperLinkColumn>


.I had the same question, and the following seems to

work. You have to use an <asp:TemplateColumn> instead of
a hyperlinkcolumn, however.

<asp:TemplateColumn HeaderText="Course (Click to Edit)">
<HeaderStyle HorizontalAlign="Left"></HeaderStyle>
<ItemTemplate>
<asp:HyperLink Runat="server" text='<%#
DataBinder.Eval(Container, "DataItem.Course_Code") %>'
navigateurl='<%
# "CourseDetails.aspx?index=0&ID=" & _
Server.URLEncode(DataBinder.Eval
(Container, "DataItem.Course_Code")) %>' />
</ItemTemplate>
</asp:TemplateColumn>
HTH.

Nov 18 '05 #3
TJS
thank you !

"fe********@seattletimes.com" <an*******@discussions.microsoft.com> wrote in
message news:17****************************@phx.gbl...
-----Original Message-----
how can I encrypt the querystring values for a

HyperLinkColumn ?

in example below I would like to encrypt value for field1
================================================= =====
<asp:HyperLinkColumn Text="View"

DataNavigateUrlField="field1"
DataNavigateUrlFormatString="page.aspx?idx=

{0}"></asp:HyperLinkColumn>


.I had the same question, and the following seems to

work. You have to use an <asp:TemplateColumn> instead of
a hyperlinkcolumn, however.

<asp:TemplateColumn HeaderText="Course (Click to Edit)">
<HeaderStyle HorizontalAlign="Left"></HeaderStyle>
<ItemTemplate>
<asp:HyperLink Runat="server" text='<%#
DataBinder.Eval(Container, "DataItem.Course_Code") %>'
navigateurl='<%
# "CourseDetails.aspx?index=0&ID=" & _
Server.URLEncode(DataBinder.Eval
(Container, "DataItem.Course_Code")) %>' />
</ItemTemplate>
</asp:TemplateColumn>
HTH.

Nov 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Jawahar Rajan | last post by:
All, I often use a querystring in my ASP pages. for example: if val > 1 then Response.redirect "val1.asp?val=1&user=UserID End if Is there a way to encrypt the querystring so anyone trying to...
1
by: lion | last post by:
my Problem: a query string passed into a html page doesn't display correctly on a mac I am just using html and javascript (no ASP, PHP or server side scripting) This is the query string:...
0
by: Jongmin | last post by:
Hi! I am making HyperLinkColumn in datagrid. It is simple to make the hyerlinkcolumn with one datafield. <asp:HyperLinkColumn Text="NAME" DataNavigateUrlField="NAME"...
0
by: vtreddy | last post by:
Hi all, Please find the code below, here I would like to bc1 column count to the DataNavigateUrlFormatString, can any one help on this, BoundColumn bc1 = new BoundColumn(); ...
0
by: VB Programmer | last post by:
I have an ASP login page. Once logged in, I get redirected to an ASPX page. According to alot of people sharing session variables is difficult between ASP and ASPX page so I was thinking about...
4
by: Gary Townsend (Spatial Mapping Ltd.) | last post by:
Good afternoon, I am building an application that uses ASP .NET, and Blackmoon FTP Server, My plan currently is to automate some user processes one of those processes is to allow them to...
0
by: TJS | last post by:
how can I encrypt the value of a hyperlink column added to a datagrid ??? I have the encryption class working but don't see how to apply the encryption in the line that creates the link. ...
4
by: Islamegy® | last post by:
I give up.. I tried everything to encrypt querystring and decrypt it back but this never success.. i use RSA encryption. I always get excption when Convert fromBase64String so i tried...
1
by: Moutan | last post by:
Hi All, I have to encode a query string defined in a hyperlinkcolumn in a datagrid. Can the Server.UrlEncode function be used here?If yes then how?Its urgent plzzz. <asp:HyperLinkColumn...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.